package com.vois.jack.btmgr.common;

public enum DebugMsgStr {
    STATE_TURNING_ON(11),
    STATE_TURNING_OFF(13),
    STATE_ON(12),
    STATE_OFF(10),
    STATE_DISCONNECTING(3),
    STATE_DISCONNECTED(0),
    STATE_CONNECTING(1),
    STATE_CONNECTED(2),
    NONE(-1);

    private final int value;
    private DebugMsgStr(int value) {
        this.value = value;
    }

    public static DebugMsgStr valueOf(int value) {
        DebugMsgStr str = NONE;
        switch (value) {
            case 11: {
                str = STATE_TURNING_ON;
            }
            break;

            case 13: {
                str = STATE_TURNING_OFF;
            }
            break;

            case 12: {
                str = STATE_ON;
            }
            break;

            case 10: {
                str = STATE_OFF;
            }
            break;

            case 3: {
                str = STATE_DISCONNECTING;
            }
            break;

            case 0: {
                str = STATE_DISCONNECTED;
            }
            break;

            case 1: {
                str = STATE_CONNECTING;
            }
            break;

            case 2: {
                str = STATE_CONNECTED;
            }
            break;

            default: {
                str = NONE;
            }
            break;
        }

        return str;
    }
}
